<%= render partial: 'list', locals: {clusters: @clusters} %>

<%= link_to '新建集群', new_cluster_path, class: 'btn btn-primary' %>

<% last_id = @clusters.max{|x| x.id}.try(:id).to_i %>
<%= link_to '第一页', clusters_path(after: 0, per_page: @per_page || 10), class: 'btn btn-primary' %>
<%= link_to_if last_id, '下一页', clusters_path(after: last_id, per_page: @per_page || 10), class: 'btn btn-primary' %>
